

set(libname tty_common_proto)

include_directories(${PROJECT_SOURCE_DIR}/third_party/cwebsocket/)

set(CWEBSOCKET_SRCS ${PROJECT_SOURCE_DIR}/third_party/cwebsocket/websocket.c 
                    ${PROJECT_SOURCE_DIR}/third_party/cwebsocket/md5.c)


if (${BUILD_JUST} STREQUAL "server")
    add_library(${libname} protocol.cpp ${CWEBSOCKET_SRCS})
endif()


if(${UNITTEST})
    add_subdirectory(unittests)
endif()
